Skip to content

[Py OV] Support pathlib.Path as ov::Any#33843

Open
almilosz wants to merge 6 commits intoopenvinotoolkit:masterfrom
almilosz:almilosz/support-pathlib-path
Open

[Py OV] Support pathlib.Path as ov::Any#33843
almilosz wants to merge 6 commits intoopenvinotoolkit:masterfrom
almilosz:almilosz/support-pathlib-path

Conversation

@almilosz
Copy link
Contributor

@almilosz almilosz commented Jan 27, 2026

Details:

  • Support passing pathlib.Path to properties that store path

Tickets:

  • ticket-id

@almilosz almilosz requested a review from a team as a code owner January 27, 2026 17:34
@github-actions github-actions bot added the category: Python API OpenVINO Python bindings label Jan 27, 2026
@almilosz almilosz requested a review from p-wysocki January 28, 2026 09:05
cache_path = tmp_path / Path("cache")

model = core.read_model(xml_path, bin_path, config={"CACHE_DIR": f"{cache_path}"})
model = core.read_model(xml_path, bin_path, config={"CACHE_DIR": cache_path})
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Am I correct that this stops testing string paths in favor of Path objects? We probably should test both.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added a test for set_property() and kept changes for test variant that uses paths test_read_model_as_path_with_user_config

@almilosz almilosz requested a review from p-wysocki February 3, 2026 10:25
@praasz praasz added this to the 2026.1 milestone Feb 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: Python API OpenVINO Python bindings

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants